<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

<c:import url="/jsp/pager/pagerForm.jsp"></c:import>

<form method="post" rel="pagerForm" action="<c:url value='/purchaseInvoice/showList'/>"
	onsubmit="return navTabSearch(this)">
	<div class="pageHeader">
		<div class="searchBar">
			<table class="searchContent">
				<tr>
					<td><label>关键词：</label> <input type="text" name="keywords" value="${param.keywords}" /></td>
				</tr>
				<tr>
					<td><label>所属月份：</label> <input name="abstractMonth" class="date" type="text" value="${param.abstractMonth}"
						readonly=" true" dateFmt="yyyy-M" /></td>
					<td><label>开票日期：</label> <input name="invoiceDate" class="date" type="text" value="${param.invoiceDate}"
						readonly=" true" dateFmt="yyyy-M-d" /></td>
				</tr>
			</table>
			<div class="subBar">
				<ul>
					<li>
						<div class="buttonActive">
							<div class="buttonContent">
								<button type="submit">搜索</button>
							</div>
						</div>
					</li>
				</ul>
			</div>
		</div>
	</div>
</form>

<div class="pageContent">

	<div class="panelBar">
		<ul class="toolBar">
			<li><a class="add" target="dialog" width="530" height="450" rel="purchaseInvoiceAdd" mask="true"
				href="<c:url value='/purchaseInvoice/showAdd'/>" title="添加进项发票"><span>添加</span></a></li>
			<li><a class="edit" target="dialog" width="530" height="450" rel="purchaseInvoiceEdit" mask="true"
				href="<c:url value='/purchaseInvoice/showEdit/{slt_objId}'/>" title="编辑进项发票"><span>编辑</span></a></li>
			<li><a class="delete" target="ajaxTodo" href="<c:url value='/purchaseInvoice/delete/{slt_objId}'/>" title="你确定要删除吗?"><span>删除</span></a></li>
			<li class="line">line</li>
			<li><a class="icon" href="javascript:$.printBox('purchaseInvoice_list_print')"><span>打印</span></a></li>
		</ul>
	</div>

	<div id="purchaseInvoice_list_print">
		<table class="list" width="1300" targetType="navTab" asc="asc" desc="desc" layoutH="141">
			<thead>
				<tr>
					<th width="5%">合计</th>
					<th width="95%" colspan="11">开票金额：${total.amount}</th>
				</tr>
				<tr>
					<th width="5%">序号</th>
					<th width="5%" orderField="orderNo" class="${pageHelper.orderField eq 'orderNo' ? param.orderDirection : ''}">单据编号</th>
					<th width="12%" orderField="company" class="${pageHelper.orderField eq 'company' ? param.orderDirection : ''}">开票单位</th>
					<th width="8%" orderField="invoiceDate" class="${pageHelper.orderField eq 'invoiceDate' ? param.orderDirection : ''}">开票日期</th>
					<th width="8%" orderField="takeDate" class="${pageHelper.orderField eq 'takeDate' ? param.orderDirection : ''}">收票日期</th>
					<th width="7%" orderField="invoiceNo" class="${pageHelper.orderField eq 'invoiceNo' ? param.orderDirection : ''}">发票号</th>
					<th width="10%" orderField="orderType" class="${pageHelper.orderField eq 'orderType' ? param.orderDirection : ''}">发票类型</th>
					<th width="8%" orderField="ai" class="${pageHelper.orderField eq 'ai' ? param.orderDirection : ''}">摘要</th>
					<th width="5%" orderField="abstractMonth" class="${pageHelper.orderField eq 'abstractMonth' ? param.orderDirection : ''}">所属月份</th>
					<th width="8%" orderField="invoiceType" class="${pageHelper.orderField eq 'invoiceType' ? param.orderDirection : ''}">开票方式</th>
					<th width="8%" orderField="orderAmount" class="${pageHelper.orderField eq 'underInvoiceAmount' ? param.orderDirection : ''}">订单金额</th>
					<th width="8%" orderField="amount" class="${pageHelper.orderField eq 'amount' ? param.orderDirection : ''}">开票金额</th>
				</tr>
			</thead>
			<tbody>
				<c:forEach var="item" items="${purchaseInvoiceList}" varStatus="s">
					<tr target="slt_objId" rel="${item.id }">
						<td>${s.index + 1}</td>
						<td>${item.orderNo}</td>
						<td>${item.company}</td>
						<td>${item.invoiceDate}</td>
						<td>${item.takeDate}</td>
						<td>${item.invoiceNo}</td>
						<td>${item.orderType}</td>
						<td>${item.ai}</td>
						<td>${item.abstractMonth}</td>
						<td>${item.invoiceType}</td>
						<td>${item.orderAmount}</td>
						<td>${item.amount}</td>
					</tr>
				</c:forEach>
			</tbody>
		</table>
	</div>

	<c:import url="/jsp/pager/panelBar.jsp"></c:import>

</div>
